package cn.manjuu.touhou.util;
	
	
import android.util.Log;
/**	
 * 对日志进行管理	
 * @author 宋疆疆	
 *	
 */	
public class Looger {	
	public static final String TAG = "sjj";	
	
	public static final int LEVEL = 0;	
	private static final int VERBOSE = Log.VERBOSE;	
	private static final int DEBUG = Log.DEBUG;	
	private static final int INFO = Log.INFO;	
	private static final int WARN = Log.WARN;	
	private static final int ERROR = Log.ERROR;	

	public static void syso(boolean flag, String msg) {	
		if(LEVEL <= VERBOSE && flag) {	
			System.out.println(msg);		
		}	
	}	
	
	public static void v(boolean flag, String msg) {	
		if (LEVEL <= VERBOSE && flag) {	
			Log.v(TAG, msg);	
		}	
	}	
	
	public static void d(boolean flag, String msg) {	
		if (LEVEL <= DEBUG && flag) {	
			Log.d(TAG, msg);	
		}	
	}	
	
	public static void i(boolean flag, String msg) {	
		if (LEVEL <= INFO && flag) {	
			Log.i(TAG, msg);	
		}	
	}	
	
	public static void w(boolean flag, String msg) {	
		if (LEVEL <= WARN && flag) {	
			Log.w(TAG, msg);	
		}	
	}	
	
	public static void e(boolean flag, String msg) {	
		if (LEVEL <= ERROR && flag) {	
			Log.e(TAG, msg);	
		}	
	}	
}	
